package com.nami.web.convert;

import com.nami.store.api.response.user.UserDTO;
import com.nami.web.vo.user.UserInfoVO;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.Mappings;
import org.mapstruct.factory.Mappers;

@Mapper
public interface UserConvert {

    UserConvert INSTANCE = Mappers.getMapper(UserConvert.class);

    @Mappings({
        @Mapping(target = "nick", source = "nickname"),
        @Mapping(target = "avatar", source = "avatarUrl")
    })
    UserInfoVO convert(UserDTO dto);


}
